package com.chenyue.cm.common.domain;

import com.baomidou.mybatisplus.annotation.FieldFill;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springframework.format.annotation.DateTimeFormat;

import java.io.Serializable;
import java.util.Date;

/**
 * <p>
 * 版本更新
 * </p>
 *
 * @author ljy
 * @since 2021-08-18
 */
@Data
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "JdAppVersion对象", description = "版本更新")
public class JdAppVersion extends Model<JdAppVersion> {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "版本号")
    private Integer versionNum;

    @ApiModelProperty(value = "版本名称")
    private String versionName;

    @ApiModelProperty(value = "ios版本")
    private Double bundle;

    @ApiModelProperty(value = "更新日志")
    private String updateContent;

    @ApiModelProperty(value = "创建时间")
    @TableField(fill = FieldFill.INSERT)
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date ct;

    @ApiModelProperty(value = "机型1安卓2Ios")
    private Integer deviceModel;


    @Override
    protected Serializable pkVal() {
        return this.id;
    }

}
